package com.ofps.forms.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.ofps.forms.common.utils.R;
import com.ofps.forms.domain.Dto.MyFormDto;
import com.ofps.forms.domain.MyForm;

import javax.servlet.http.HttpServletRequest;
import java.util.List;
import java.util.Map;

/**
 * 表单相关操作
 *
 * @author pyn
 * @email 1661829453@qq.com
 * @date 2022-05-02 20:58:29
 */
public interface MyFormService extends IService<MyForm> {


    //修改表单状态
    R editFormStatus(Map<String, Object> body);

    //显示原始表单
    R showForm(HttpServletRequest request, Map<String, Object> body);

    //提交表单填写情况
    R submitForm(HttpServletRequest request, Map<String, Object> body);

    //根据id删除表单
    R deleteFormById(Map<String, Object> body);

    //查询作答结果
    R checkResult(Map<String, Object> body);

    //保存自定义表单
    R saveForm(MyForm myForm);

    //查询自己创建的表单
    R queryFormList(MyFormDto formDto);

    //查询一个表单的所有填写结果
    Map<String, Object> QueryFormResult(HttpServletRequest request, Map<String, Object> body);

    List<MyForm> querywithId(String Id);

    Map<String, Object> summerizeForm(String FormId);

    R saveWork(HttpServletRequest request , Map<String , Object> body);

    List<MyForm> queryWithdepartmentId(Map<String, Object> body);

}

